{extend name="public/base"}
{block name='sep'}
<!-- 首页导航下搜索 -->
<div class="fly-case-header">
    <form action="{:url('home/search/index')}" method="get" class="fly-extend-banner-search">
        <input name="lm" value="0" id="t_doc"  type="hidden">
        <div class="layui-inline">
            <input placeholder="请输入文档关键字" name="searchword" autocomplete="off" value="" class="layui-input">
        </div>
        <button class="layui-btn"><i class="layui-icon">&#xe615;</i></button>
    </form>
    <p class="fly-case-year">资料库共有<span style="color:#FFB800;">&nbsp;{$totaldocnum}&nbsp;</span>个文档</p>
</div>
{/block}
{block name='main'}


<!-- 首页搜索结束 -->
<div class="fly-main mtop20" >
    <!-- 幻灯片 -->
    <div class="fly-tab-border fly-case-tab">
        <div class="layui-carousel" id="slide">
            <div carousel-item="">
                {volist name="slide" id="v" key='k'}
                {$v.url}
                    <div><a href="{$v.url}" target="_blank">
                        <img src="{:upload_url($v['img'], 'slide')}" alt="{$v.name}" class="img-responsive itm-banner" data-adaptive-background='{$k}'></a></div>
                {/volist}
            </div>
        </div>
    </div>
    <!-- 热门专辑开始 -->
    <div class="layui-tab layui-tab-brief">
        <ul class="layui-tab-title">
            <li class="layui-this"><a href="" class="font16">热门专辑</a></li>
            <li style="float: right;"><a href="{:url('album/index')}" target="_blank" >全部专辑</a></li>
        </ul>
    </div>
    {empty name="tjzj"}
        <div class="fly-none">没有相关数据</div>
    {/empty}
    <ul class="fly-zj-list">
        {volist name="tjzj" id="vo" offset="0" length='4'}
            <li data-id="123"> <a class="fly-zj-img" href="{:url('album/zjinfo',array('id'=> $vo['id']))}" target="_blank">
                <img src="{:upload_url($vo['img'], 'album')}" /> <cite class="layui-btn layui-btn-primary layui-btn-small">查看</cite> </a>
                <h3><a href="{:url('album/zjinfo',array('id'=> $vo['id']))}" target="_blank">{$vo.title}</a></h3>
                <div class="fly-zj-info">
                    {volist name="vo['zhuanji']" id="vo1"}
                        <p><a class="fly-zj-nums fly-zj-active" href="{:url('doc/doccon',array('id'=>$vo1['id']))}"  target="_blank" style=" padding:0 5px;">
                            <i class="ic ic-{$vo1.ext|strtolower}"></i>{$vo1.title|msubstr= 16,0,true}</a>
                            <span style="float: right;color: #999">
                                <i class="iconfont xico" title="人气">&#xe60b;</i>{$vo1.hits}</span></p>
                        {/volist}
                </div>
            </li>
        {/volist}
        </li>

    </ul>
    <!-- 热门专辑开始结束 -->
    <!-- 最新文档开始 -->
    <div class="layui-tab layui-tab-brief">
        <ul class="layui-tab-title">
            <li class="layui-this"><a href="" class="font16">最新上传</a></li>
            <li style="float: right;"><a href="{:url('doc/doclist')}" target="_blank" >全部文档</a></li>
        </ul>
    </div>
    <ul class="fly-case-list">
        {volist name="indexDocList" id="vo" }
            <li >
                <a class="fly-case-img" href="{:url('doc/doccon',array('id'=>$vo['id']))}" target="_blank">
                    <img src="{:docfile($vo.html,$vo.imgurl)}"  width="166px"/> <cite class="layui-btn layui-btn-primary layui-btn-small">查看</cite> </a>
                <h3><i class="ic ic-{$vo.ext}"></i>
                    <a href="{:url('doc/doccon',array('id'=>$vo['id']))}" target="_blank">{$vo.title}</a></h3>
                <div class="fly-case-info">
                    <p class="layui-elip" style="font-size: 12px;"><span style="color: #666;">{$vo.create_time|fdate}</span> <span style="float: right;">
                        <i class="iconfont xico" title="人气">&#xe60b;</i>{$vo.hits}</span>
                    </p>
                </div>
            </li>
        {/volist}
    </ul>
    <!-- 最新文档结束 -->
    <!-- 友情链接 -->
    {include file='public/flink'}
    <!-- 友情链接结束 -->
</div>
<script>
    var ggstatus = "{:config('web_config.gonggao_status')}";
    if (ggstatus == 1) {
        layui.use(['form' ,'jquery'], function(){
            var form = layui.form , $ = layui.jquery ;
            layer.open({
                type: 1
                ,title: false
                ,closeBtn: false
                ,area: '300px;'
                ,shade: 0.8
                ,id: 'LAY_layuipro'
                ,btn: [ '我知道了']
                ,btnAlign: 'c'
                ,moveType: 1 //拖拽模式，0或者1
                ,content: '{:config(\'web_config.gonggao_protocol\')}'
                ,success: function(layero){
                }
            });

        });
    }
</script>
<script>
    layui.use('carousel', function(){
        var carousel = layui.carousel;
        //建造实例
        carousel.render({
            elem: '#slide'
            ,width: '100%' //设置容器宽度
            ,arrow: 'always' //始终显示箭头
            ,height:'200px'
            //,anim: 'updown' //切换动画方式
        });
    });

</script>
<script>
    layui.config({
        version: "3.0.0"
        ,base: '__PUBLIC__/theme/blueideal/mods/' //这里实际使用时，建议改成绝对路径
    }).extend({
        fly: 'index'
    }).use('fly');
</script>



{/block}